package org.coderjonny.service.fallback.service;

import org.coderjonny.bean.Product;
import org.coderjonny.dto.Request;
import org.coderjonny.dto.Result;
import org.coderjonny.dto.product.ProductId;
import org.coderjonny.dto.product.UpdateStock;
import org.coderjonny.feign.ProductService;
import org.springframework.stereotype.Service;

@Service
public class ProductServiceFallback implements ProductService {
    @Override
    public Result<Product> getByProductId(Request<ProductId> request) {
        return Result.error("降级容错Product");
    }

    @Override
    public Result<String> updateStockById(Request<UpdateStock> request) {
        return Result.error("降级容错，更新异常");
    }
}
